package com.emm.yixun.common.enums;

import java.io.Serializable;

import org.apache.commons.lang3.StringUtils;


public enum ProcessTypeEnums  implements Serializable{
	PROCESS_KEY_1("mktPriceScheme","价格方案审批流程"),
	PROCESS_KEY_2("mktPriceSchemeInvalid","价格方案无效审批流程"),
	PROCESS_KEY_3("cusPayDeposit","认筹审批流程"),
	PROCESS_KEY_4("cusPayDepositRetreat","退筹审批流程"),
	PROCESS_KEY_5("cusSubscribe","认购审批流程"),
	PROCESS_KEY_6("cusCubscribeRetreat","退认购审批流程"),
	PROCESS_KEY_7("cusCubscribeChangeHouse","认购换房审批流程"),
	PROCESS_KEY_8("cusCubscribeAndSignedChangeName","更名审批流程"),
	PROCESS_KEY_9("cusCubscribeDelaySingedOne","延期签约审批(15天内)流程"),
	PROCESS_KEY_10("cusCubscribeDelaySingedTwo","延期签约审批(15到30天)流程"),
	PROCESS_KEY_11("cusCubscribeDelaySingedThree","延期签约审批(30天以上)流程"),
	PROCESS_KEY_12("cusSigned","签约审批流程"),
	PROCESS_KEY_13("cusSignedDiscount","签约折扣审批流程"),
	PROCESS_KEY_14("cusSignedChangeHouse","签约换房审批流程"),
	PROCESS_KEY_15("cusSignedCheckOut","签约退房审批流程"),
	PROCESS_KEY_16("dealReserveArea","面积补差审批流程"),
	PROCESS_KEY_17("cusSubscribeDiscount","认购折扣审批流程");
	
	private final String no;
	private final String des;
	
	/**
	 * 私有构造函数
	 * @param code
	 * @param description
	 */
	ProcessTypeEnums(String no, String des) {
		this.no = no;
		this.des = des;
	}

	/**
	 * @return Returns the no.
	 */
	public String getNo() {
		return no;
	}

	/**
	 * @return Returns the des.
	 */
	public String getDes() {
		return des;
	}
	
	public static ProcessTypeEnums getByNo(String no) {
		if(StringUtils.isBlank(no)){
			return null;
		}
		for (ProcessTypeEnums menum : values()) {
			if (menum.getNo().equals(no)) {
				return menum;
			}
		}
		return null;
	}
}
